package com.aliyun.heiyu.powermaster.server.dao.enums;

public enum UserErrorEnum {
    USER_OK(0, "请求成功"),
    USER_LOGINOUT_OK(1, "注销成功"),
    USER_LOGINOUT_FAILED(2, "注销失败"),
    USER_INVALID_NAME_ERROR(301, "用户名不符合规范"),
    USER_INVALID_PSW_ERROR(302, "密码不符合规范"),
    USER_REGIST_NAME_EXISTED_ERROR(303, "用户名已存在"),
    USER_REGIST_ERROR(304, "用户注册失败"),
    USER_OR_PSW_ERROR(305, "用户名或密码错误"),
    USER_NOT_EXIT_ERROR(306, "用户不存在"),
    USER_PSW_SAME_ERROR(307, "新旧密码相同"),
    USER_PSW_RESET_ERROR(308, "密码修改或重置失败"),
    USER_INVALID_TOKEN_ERROR(309, "登录失效"),
    USER_LOGIN_FIRST_ERROR(310, "账号新创建或者已经过期，请先修改密码"),
    USER_TOKEN_DISPATCH_ERROR(311, "token派发失败"),
    USET_STATUS_ACTIVATED_ERROR(312, "状态激活失败"),
    USET_DELETE_FAILED_ERROR(313, "删除用户失败"),
    USET_FIND_FAILED_ERROR(314, "用户查询失败"),
    ADMIN_STATUS_ERROR(315, "当前管理员状态出错"),
    ADMIN_NOT_EXIT_ERROR(316, "管理员不存在"),
    USER_NO_PERMISSION_ERROR(317, "当前操作没有权限"),
    ACCOUNT_NOT_ACTIVE_ERROR(318, "账号已被锁定，请20分钟后再试,或提交申请解锁"),
    ROLE_MODIFY_FAILED_ERROR(319, "更改权限失败"),
    NAME_INVALID_ERROR(320, "真实姓名不符合规范"),
    PSW_INPUT_COUNT_ERROR(321, "用户名或密码错误，n次重试后将锁定账号"),
    USER_INVALID_ROLE_ERROR(323, "权限选择不符合规范"),
    USER_AGAINPSW_ERROR(324, "两次密码输入不一致"),
    USER_VALIDATION_ERROR(325, "该账号正在验证中，请耐心等候"),
    USER_VALIDATION_FAILED_ERROR(326, "用户验证失败"),
    SIGN_ERROR(327, "签名失效"),
    EMAIL_INVALID_ERROR(328, "邮箱输入不符合规范"),
    PHONE_INVALID_ERROR(329, "手机号码输入不符合规范"),
    REPEAT_LOGIN_ERROR(330, "当前用户已登录,请勿重复登录"),
    Sms_Code_ERROR(331, "短信验证码错误或者失效，请重新发送"),
    Sms_Code_INVALID_ERROR(332, "短信验证码不符合规范，请重新输入"),
    DATA_RANGE_ERROR(333, "请在规定访问时间范围进行访问"),
    USER_STRATEGY_ERROR(334, "用户时间访问策略错误"),
    USER_LOGIN_MAX_ERROR(335, "当前系统已达最大访问上限，请稍后再试"),
    USER_PSW_SAME_AS_DEFAULT_ERROR(336, "初始密码，请重新修改"),
    PHONE_EXISTED_ERROR(337, "手机号已经存在"),
    EMAIL_EXISTED_ERROR(338, "邮箱已经存在"),
    EMAIL_ERROR(339, "验证码错误"),
    USER_DORMANCY(340, "该账号处于休眠状态，请重新激活"),
    PHONE_ERROR(341, "手机号码输入错误,请重新输入"),
    ACCOUNT_CANCELLATION_ERROR(343, "该账号已经注销，请重新申请"),
    IP_FORMAT_WRONG(347, "ip格式有误"),

    RECIPIENT_NOT_NULL(348, "收件人不能为空"),
    SENDER_NOT_NULL(349, "发送人不能为空"),

    CERTIFIED_SSL_NOT_NULL(350, "认证SSL不能为空"),

    CERTIFIED_TLS_NOT_NULL(351, "认证TLS不能为空"),
    PORT_ERROR(352,"端口错误"),
    ;


    private int code;
    private String msg;


    UserErrorEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
